package ch.ti.bfh.app.loodel.service;

import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.userdetails.User;

import java.util.Collection;

public class LoodelUserDetails extends User {
    private final MemberData memberData;

    public LoodelUserDetails(MemberData memberData, Collection<? extends GrantedAuthority> authorities) {
        super(memberData.getFullName(), "Not/Set", authorities);
        this.memberData = memberData;
    }

    public MemberData getMember() {
        return memberData;
    }

}
